import os
import logging

def setup_logging():
    """设置日志配置"""
    os.makedirs('output/logs', exist_ok=True)
    logging.basicConfig(
        filename='output/logs/app.log',
        level=logging.INFO,
        format='%(asctime)s - %(levelname)s - %(message)s',
        encoding='utf-8'
    )

def create_output_dirs():
    """创建输出目录"""
    os.makedirs('output/results', exist_ok=True)
    os.makedirs('output/logs', exist_ok=True)